import Vue from 'vue'
import Router from 'vue-router'
import { basics } from './basics'


Vue.use(Router)

const router = new Router({
  mode: 'history',  //history去掉#号
  // base: '/opt/app/m2m/new-weixin-ui/',
  routes: [...basics]
})

// 变化名字
router.beforeEach((to, from, next) => {
  document.title = to.meta.title
  next()
})

export default router